<template>
    <div class="dramInfoBox">
        <ul>
            <li>
                <p class="num">1</p>
                <p>地块</p>
            </li>
            <li>
                <p class="num">{{parseFloat(options.distance||0).toFixed(2)}}m</p>
                <p>周长</p>
            </li>
            <li>
                <p class="num">{{parseFloat(options.area||0).toFixed(2)}}亩</p>
                <p>面积</p>
            </li>
        </ul>
        <div class="btnBox"><el-button type="danger" plain class="myBtn" icon="delete" @click="emit('btnClick')">清空</el-button></div>
    </div>
</template>
<script setup>
import {ref} from "vue"
const props = defineProps({
    options:{
        type:Object,
        default:{}
    }
})
const emit = defineEmits(['btnClick'])
</script>
<style lang="scss" scoped>
.dramInfoBox{
    position: absolute;
    z-index: 1000;
    height: 50px;
    //min-width: 200px;
    background-color: #000;
    left: 50%;
    bottom: 50px; 
    border-radius: 1px;
    transform: translateX(-50%);
    -webkit-transition: translateX(-50%);
    box-shadow: 0 0 5px #686767;
    .btnBox{
        display: flex;
        justify-content: center;
        width: 100%;
        margin: 0;
        transform: translateY(10px);
        -webkit-transition: translateY(10px);
    }
    ul{
        display: flex;
        list-style: none;
        li{
            flex: 1;
            flex-shrink: 0;
            line-height: 20px;
            text-align: center;
            padding: 5px 10px 0 10px;
            white-space: nowrap;
            p{
                color: #fff;
                white-space: nowrap;
                &.num{
                    color: #48b27a;
                    font-weight: bold;
                }
            }
            
        }
    }
}
</style>